package com.hut.oa.model.dao.system;

import java.util.List;

import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.PagingAndSortingRepository;

import com.hut.oa.model.bean.Status;

public interface StatusDao extends PagingAndSortingRepository<Status, Long>{
	//帖子状态
	@Query("from Status s where s.module='discuss_area'")
	List<Status> allStatus();
	
	List<Status> findAll();
	
	Page<Status> findAll(Pageable pageable);
	
	List<Status> findByModule(String module);//根据指定模块查询所有类型
	
	Status findById(Long id);
}
